package com.x.mvp.injection.modules;

import android.app.Application;

import com.x.mvp.utils.GlideCatch;

import javax.inject.Singleton;

import dagger.Module;
import dagger.Provides;

@Module
public class AppModule {
    private Application application;

    public AppModule(Application application) {
        this.application = application;
    }

    @Provides
    @Singleton
    public Application provideApplication() {
        return application;
    }

    @Singleton
    @Provides
    public GlideCatch provideGliCache(Application application) {
        return new GlideCatch(application);
    }
}